package mqtt

import "reflect"

type Publish struct {
	Topic       string
	Qos         byte
	Retained    bool
	PayloadType reflect.Type
}

func newPublish(topic string, qos byte, retained bool, payload interface{}) *Publish {
	return &Publish{
		Topic:       topic,
		Qos:         qos,
		Retained:    retained,
		PayloadType: reflect.TypeOf(payload),
	}
}

var (
	TEST = newPublish("test", 1, false, &TestMsg{})
)
